gdk: Drop gdk_seat_get_logical_pointers()
authorCarlos Garnacho <carlosg@gnome.org>
Mon, 22 Jun 2020 22:24:12 +0000 (00:24 +0200)
committerCarlos Garnacho <carlosg@gnome.org>
Tue, 23 Jun 2020 21:42:53 +0000 (23:42 +0200)
Events come from hardware devices and are handled by controllers,
there's no need to use logical pointers, nor to peek them. Drop this
unused API.

docs/reference/gdk/gdk4-sections.txt
gdk/gdkseat.c
gdk/gdkseat.h
gdk/gdkseatdefault.c
gdk/gdkseatprivate.h
gdk/wayland/gdkdevice-wayland.c

index 8b72b2ddb24410d76a0649e269b0ed3f4bb7c9d9..158fba7ec17993281c63d837bb9a2b33fb3a00b1 100644 (file)
@@ -441,7 +441,6 @@ gdk_seat_get_capabilities
 gdk_seat_get_pointer
 gdk_seat_get_keyboard
 gdk_seat_get_physical_devices
-gdk_seat_get_logical_pointers
 
 <SUBSECTION Standard>
 GDK_SEAT
index d30e44d7c8c1aff48ee5c20276b58a34097f8b97..6505169c33f84cda139d8ddad795fb6d7b01b3e9 100644 (file)
@@ -446,31 +446,3 @@ gdk_seat_get_tool (GdkSeat *seat,
   seat_class = GDK_SEAT_GET_CLASS (seat);
   return seat_class->get_tool (seat, serial, hw_id);
 }
-
-/**
- * gdk_seat_get_logical_pointers:
- * @seat: The #GdkSeat
- * @capabilities: Queried capabilities
- *
- * Returns all logical pointers with the given capabilities driven by
- * this @seat.
- *
- * On most windowing system backends this function will return a list
- * with a single element (meaning that all input devices drive the same
- * on-screen cursor).
- *
- * In other windowing systems where there can possibly be multiple
- * foci (e.g. Wayland), this function will return all logical #GdkDevices
- * that represent these.
- *
- * Returns: (transfer container) (element-type GdkDevice): A list
- *   of logical pointing devices
- */
-GList *
-gdk_seat_get_logical_pointers (GdkSeat             *seat,
-                               GdkSeatCapabilities  capabilities)
-{
-  g_return_val_if_fail (GDK_IS_SEAT (seat), NULL);
-
-  return GDK_SEAT_GET_CLASS (seat)->get_logical_pointers (seat, capabilities);
-}
index 5bc912ac7ebcecd31b71c5f390d556cbaf0bea5a..960a6e306bbf698d56ca8dde89651d6ba93511b3 100644 (file)
@@ -83,10 +83,6 @@ GdkDevice *    gdk_seat_get_pointer             (GdkSeat             *seat);
 GDK_AVAILABLE_IN_ALL
 GdkDevice *    gdk_seat_get_keyboard            (GdkSeat             *seat);
 
-GDK_AVAILABLE_IN_ALL
-GList *        gdk_seat_get_logical_pointers    (GdkSeat             *seat,
-                                                 GdkSeatCapabilities  capabilities);
-
 G_END_DECLS
 
 #endif /* __GDK_SEAT_H__ */
index 822c8d2e64e5edaa5662756f0716c2dcfcc6a9bd..04906898fdff400c04d7deae9d0ec235b7c48a1d 100644 (file)
@@ -305,18 +305,6 @@ gdk_seat_default_get_tool (GdkSeat *seat,
   return NULL;
 }
 
-static GList *
-gdk_seat_default_get_logical_pointers (GdkSeat             *seat,
-                                      GdkSeatCapabilities  capabilities)
-{
-  GList *pointers = NULL;
-
-  if (capabilities & GDK_SEAT_CAPABILITY_ALL_POINTING)
-    pointers = g_list_prepend (pointers, gdk_seat_get_pointer (seat));
-
-  return pointers;
-}
-
 static void
 gdk_seat_default_class_init (GdkSeatDefaultClass *klass)
 {
@@ -332,7 +320,6 @@ gdk_seat_default_class_init (GdkSeatDefaultClass *klass)
 
   seat_class->get_logical_device = gdk_seat_default_get_logical_device;
   seat_class->get_physical_devices = gdk_seat_default_get_physical_devices;
-  seat_class->get_logical_pointers = gdk_seat_default_get_logical_pointers;
 
   seat_class->get_tool = gdk_seat_default_get_tool;
 }
index b5139df8ee4a662b72805ad9d8e84d002847bc95..07672f6a445723d33b21626edb11e91a9e84dcfb 100644 (file)
@@ -60,8 +60,6 @@ struct _GdkSeatClass
   GdkDeviceTool * (* get_tool) (GdkSeat *seat,
                                 guint64  serial,
                                 guint64  tool_id);
-  GList *     (* get_logical_pointers) (GdkSeat             *seat,
-                                        GdkSeatCapabilities  capabilities);
 };
 
 void gdk_seat_device_added   (GdkSeat   *seat,
index d9b3ee8fa5e9f3062ec6decb64242768f64aac71..fe4d767e4884b663da6c582d8d0ca30c69087bf8 100644 (file)
@@ -4767,32 +4767,6 @@ gdk_wayland_seat_get_physical_devices (GdkSeat             *seat,
   return physical_devices;
 }
 
-static GList *
-gdk_wayland_seat_get_logical_pointers (GdkSeat             *seat,
-                                       GdkSeatCapabilities  capabilities)
-{
-  GdkWaylandSeat *wayland_seat = GDK_WAYLAND_SEAT (seat);
-  GList *logical_devices = NULL;
-
-  if (capabilities & GDK_SEAT_CAPABILITY_POINTER)
-    logical_devices = g_list_prepend (logical_devices, wayland_seat->logical_pointer);
-  if (capabilities & GDK_SEAT_CAPABILITY_TOUCH)
-    logical_devices = g_list_prepend (logical_devices, wayland_seat->logical_touch);
-  if (capabilities & GDK_SEAT_CAPABILITY_TABLET_STYLUS)
-    {
-      GList *l;
-
-      for (l = wayland_seat->tablets; l; l = l->next)
-        {
-          GdkWaylandTabletData *tablet = l->data;
-
-          logical_devices = g_list_prepend (logical_devices, tablet->logical_device);
-        }
-    }
-
-  return logical_devices;
-}
-
 static void
 gdk_wayland_seat_class_init (GdkWaylandSeatClass *klass)
 {
@@ -4806,7 +4780,6 @@ gdk_wayland_seat_class_init (GdkWaylandSeatClass *klass)
   seat_class->ungrab = gdk_wayland_seat_ungrab;
   seat_class->get_logical_device = gdk_wayland_seat_get_logical_device;
   seat_class->get_physical_devices = gdk_wayland_seat_get_physical_devices;
-  seat_class->get_logical_pointers = gdk_wayland_seat_get_logical_pointers;
 }
 
 static void